@datasets=("GSE12093","GSE12276","GSE2034","GSE26971","GSE29271","GSE5327","GSE6532");
$dir="/data4/bsi/bioinf_ext1/s113759/BRCA/EXPR_GEO";
for($i=0;$i<@datasets;$i++)
{
	$d="$dir/$datasets[$i]/output";
	$ls=`ls $d`;
	open(WRBUFF,">$dir/$datasets[$i]/file");
	@ls=split("\n",$ls);
	for($y=0;$y<@ls;$y++)
	{
		print WRBUFF "$dir/$datasets[$i]/output/$ls[$y]\n";
	}
	$y=0;
	system("cut -f1 $dir/$datasets[$i]/output/$ls[$y] > $dir/$datasets[$i]/ref_file");
}
$i=@datasets-1;
$d="$dir/$datasets[$i]/output_hgu133a";
$ls=`ls $d`;
open(WRBUFF,">$dir/$datasets[$i]/file_hgu133a");
@ls=split("\n",$ls);
for($y=0;$y<@ls;$y++)
{
	print WRBUFF "$dir/$datasets[$i]/output_hgu133a/$ls[$y]\n";
}
close(WRBUFF);
$y=0;
system("cut -f1 $dir/$datasets[$i]/output_hgu133a/$ls[$y] > $dir/$datasets[$i]/ref_file_hgu133a");
